@model List<ToDoListWeb.Models.Matter>
    @section head{
        <link rel="stylesheet" href="~/css/UpcomingMatters.css" />
    }
    @{
    }

    <div class="upcomingMatter">
        <div class="allUpcomingMatters">
            <table id="table-matters">
                <tr>
                    <th><h3>事项</h3></th>
                    <th><h3>备注</h3></th>
                    <th><h3>过期时间</h3></th>
                </tr>
                @foreach (var item in Model)
                {
                    <tr>

                        @if (item.OverTime >= DateTime.Now.AddDays(0))
                        {
                            <th><h4 class="redh4">@item.MatterContent</h4></th>
                            <th><h4 class="redh4">@item.Remark</h4></th>
                            <th><h4 class="redh4">@item.OverTime.Value.ToString("yyyy-MM-dd")</h4></th>
                        }
                        @if (item.OverTime > DateTime.Now.AddDays(1) && item.OverTime <= DateTime.Now.AddDays(2))
                        {
                            <th><h4 class="FFh4">@item.MatterContent</h4></th>
                            <th><h4 class="FFh4">@item.Remark</h4></th>
                            <th><h4 class="FFh4">@item.OverTime.Value.ToString("yyyy-MM-dd")</h4></th>
                        }
                        @if (item.OverTime > DateTime.Now.AddDays(2) && item.OverTime <= DateTime.Now.AddDays(3))
                        {
                            <th><h4>@item.MatterContent</h4></th>
                            <th><h4>@item.Remark</h4></th>
                            <th><h4>@item.OverTime.Value.ToString("yyyy-MM-dd")</h4></th>
                        }
                    </tr>
                }
            </table>
        </div>
    </div>
